﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Collections;

namespace Apq
{
	/// <summary>
	/// 事件参数基础类
	/// </summary>
	public class EventArgsBase : EventArgs
	{
		private ArrayList _PIns = new ArrayList();
		/// <summary>
		/// 输出参数列表
		/// </summary>
		public ArrayList PIns
		{
			get { return _PIns; }
		}
	}

	/// <summary>
	/// 事件参数限定为一个字符串
	/// </summary>
	public class EventArgsText : EventArgsBase
	{
		/// <summary>
		/// 获取或设置事件关联的字符串
		/// </summary>
		public string Text
		{
			set
			{
				PIns.Clear();
				PIns.Add(value);
			}
			get
			{
				if (PIns.Count < 1)
				{
					return null;
				}
				return Apq.Convert.ChangeType<string>(PIns[0]);
			}
		}
	}
}
